#pragma once
#include "PointLight.h"

class SpotLight : public PointLight
{
public:
	SpotLight(void);

	~SpotLight(void);

	void setTarget(const FLOAT x, const FLOAT y, const FLOAT z);

	void setPosition(const FLOAT x, const FLOAT y, const FLOAT z);

	void setDecay(const FLOAT decay)
	{
		this->decay = decay;
	}

	const FLOAT getDecay()
	{
		return decay;
	}

	const D3DXMATRIX getViewMatrix();

	const D3DXMATRIX getProjMatrix();

	const D3DXMATRIX getViewProjMatrix();

	const D3DXMATRIX getWorldMatrix();

	const D3DXVECTOR4 getDirection4();
private:
	void updateLook();

	FLOAT decay;

	D3DXMATRIX matProj;

	D3DXMATRIX matView;

	D3DXVECTOR3 target;

	D3DXVECTOR3 up;

};
